package com.cz.datafetcher.controller;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.cz.datafetcher.entity.FetchDevices;
import com.cz.datafetcher.entity.search.FetchDevicesSearch;
import com.cz.datafetcher.service.FetchDevicesService;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/fetchdevices")
@Api(tags = "采集设备")
public class FetchDevicesController extends SingleTabWithForginControllerBase<FetchDevices,Integer, FetchDevicesService, FetchDevicesSearch>
{
    @Override
    protected QueryWrapper<FetchDevices> buildQueryWrapper(FetchDevicesSearch fetchDevicesSearch) {
        QueryWrapper<FetchDevices> qw = new QueryWrapper<>();
        // todo 完善搜索条件
        return qw;
    }

    @Override
    protected Integer getKeyFromObj(FetchDevices fetchDevices) {
        return fetchDevices.getId();
    }
}
